/*
 * helper.h
 *
 *      Author: Jerome RD Soine and Christoph A Brand
 *      Institution: Schwarz goup, Institute for Theoretical Physics, Heidelberg University, Germany
 */

#ifndef HELPER_H_
#define HELPER_H_


#include <vector>

class Helper{
public:
	static void invert2x2Matrix(vector<double> & matrix){
		double a = matrix[0], b=matrix[1],c=matrix[2],d=matrix[3];

		double det = a*d-b*c;
		double A = d/det;
		double B = -b/det;
		double C = -c/det;
		double D = a/det;

		matrix[0] = A;
		matrix[1] = B;
		matrix[2] = C;
		matrix[3] = D;

	}
};

#endif /* HELPER_H_ */
